package uutalk.netcloud.talk.base.util;

import android.content.Context;
import android.content.SharedPreferences;
import android.preference.PreferenceManager;

/**
 * Created by Administrator on 2017/7/18.
 */

public class PreUtil {


    public static void saveBoolean(Context context ,String key, boolean value){
       SharedPreferences sharedPreferences = PreferenceManager.getDefaultSharedPreferences(context);
        sharedPreferences.edit().putBoolean(key,value).commit();
    }

    public static boolean getBoolean(Context context ,String key){
        SharedPreferences sharedPreferences = PreferenceManager.getDefaultSharedPreferences(context);
        return sharedPreferences.getBoolean(key,false);
    }


}
